Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3130 site bug issue with the page self hostedlatestbackup and restore #3626

Conversation

billy-the-fish
Copy link
Contributor

No description provided.

Copy link

Allow 10 minutes from last push for the staging site to build. If the link doesn't work, try using incognito mode instead. For internal reviewers, check web-documentation repo actions for staging build status. Link to build for this PR: http://docs-dev.timescale.com/docs-3130-site-bug-issue-with-the-page-self-hostedlatestbackup-and-restore

@saj
Copy link

saj commented Dec 2, 2024

(I come from #3130.)

This looks good to me. Thanks.

The article finishes by noting the following.

On a self hosted TimescaleDB instance with postgres superuser access you can take a complete dump of all PostgreSQL databases in a cluster including global objects that are common to all databases, namely database roles, tablespaces, and privilege grants using pg_dumpall.

However, it does not explain how restore a dump from pg_dumpall.
Is it still necessary to execute timescaledb_pre_restore() and timescaledb_post_restore() around each individual database?
Or to CREATE EXTENSION timescaledb?

(I had wondered this myself about a week ago, and had come to the conclusion that it is easier to dump each database independently when using logical backups.)

self-hosted/backup-and-restore/logical-backup.md Outdated Show resolved Hide resolved
1. Back up the hypertable schema:

```bash
pg_dump -s -d $SOURCE --table conditions -N _timescaledb_internal | \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn't' t understand the reason for adding -N _timescaledb_internal | grep -v _timescaledb_internal. Since we recommend creating hypertable on target again, we don't really need to dump the schema of chunks from _timescaledb_internal.

Copy link
Contributor Author

@billy-the-fish billy-the-fish Dec 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:-), i would never have got that one. Removed.

Comment on lines 28 to 30
- Install the PostgreSQL client tools on your migration machine.

This includes `psql`, and `pg_dump`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An extra line seems odd

Suggested change
- Install the PostgreSQL client tools on your migration machine.
This includes `psql`, and `pg_dump`.
- Install the PostgreSQL client tools — `psql`, and `pg_dump`, on your migration machine.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point, updated.

Comment on lines 34 to 38
You backup and restore an entire database using `pg_dump` and `psql`. in Terminal:

<Procedure>

In Terminal:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"In terminal" is repeated. Also, let's use keep "terminal" lower case.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dearie me, thank you. Updated.

@billy-the-fish billy-the-fish merged commit 8708fd9 into latest Dec 9, 2024
3 checks passed
@billy-the-fish billy-the-fish deleted the 3130-site-bug-issue-with-the-page-self-hostedlatestbackup-and-restore branch December 9, 2024 14:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Site Bug] Issue with the page: /self-hosted/latest/backup-and-restore/
4 participants